import Vue from 'vue'
import App from './App'

import mqttTool from 'common/mqtt.js'

// api
import * as api from 'common/api.js'

// 常用方法
import {
  navTo,
  showToast,
  showSuccess,
  showError,
  getShareUrlParams
} from './common/app'

Vue.config.productionTip = false

App.mpType = 'app'

// 挂载全局函数
Vue.prototype.$tip = showToast
Vue.prototype.$success = showSuccess
Vue.prototype.$error = showError
Vue.prototype.$navTo = navTo
Vue.prototype.$getShareUrlParams = getShareUrlParams
Vue.prototype.$api = api
Vue.prototype.$mqtt = mqttTool
// 实例化应用
const app = new Vue({
	...App
})
app.$mount()


